{{include template('public/header','admin')}}
<body>
    <div id="page-wrapper">
        <!-- /.row -->
        <div class="row">
            <div class="col-lg-12">
                <fieldset>
                    <legend>{{$action}}{{$title}}</legend>
                    <form class="form-horizontal" role="form" method="post" onsubmit="return dosub(this)">
                        <input type='hidden' name='catid' value="{{$item['catid']}}" />
                        <input type='hidden' name='catdir' value="{{$item['catdir']}}" />
                        <div class="form-group">
                            <label for="title" class="col-sm-2 control-label">标题</label>
                            <div class="col-sm-10">
                                <input type="text" class="form-control" id="title" name="title" value="{{$item['title']}}" placeholder="请输入标题" style="width: 825px;"/>
                            </div>
                        </div>
                        <div class="form-group">
                            <label for="keywords" class="col-sm-2 control-label">栏目关键字</label>
                            <div class="col-sm-10">
                                <input type="text" class="form-control" id="keywords" name="keywords" value="{{$item['keywords']}}" style="width: 825px;"   placeholder="请使用,隔开"/>
                            </div>
                        </div>
                        <div class="form-group">
                            <label for="description" class="col-sm-2 control-label">栏目描述</label>
                            <div class="col-sm-10">
                                <textarea class="form-control" rows="3" id="description" name="description" style="width: 825px;">{{$item['description']}}</textarea>
                            </div>
                        </div>
                        <div class="form-group">
                            <label for="content" class="col-sm-2 control-label">页面内容</label>
                            <div class="col-sm-10">
                                <!-- 加载编辑器的容器 -->
                                <script id="content" name="content" type="text/plain" style="width:825px;height:350px;">
                                    {{$item['content']}}
                                </script>
                            </div>
                        </div>
                        <div class="form-group">
                            <div class="col-sm-offset-2 col-sm-10">
                                <input type='submit' name='dosubmit' class='btn btn-primary' value='保存' />
                                <a href="/admin/newsclass" class="btn btn-default radius">取消</a>
                            </div>
                        </div>
                        <link href="/static/plugins/umeditor/themes/default/css/umeditor.css" type="text/css" rel="stylesheet">
                        <!-- 配置文件 -->
                        <script type="text/javascript" src="/static/plugins/umeditor/umeditor.config.js"></script>
                        <!-- 编辑器源码文件 -->
                        <script type="text/javascript" src="/static/plugins/umeditor/umeditor.min.js"></script>
                        <script type="text/javascript" src="/static/plugins/umeditor/lang/zh-cn/zh-cn.js"></script>
                        <!-- 实例化编辑器 -->
                        <script type="text/javascript">
                        var ue = UM.getEditor('content');
                        </script>
                    </form>
                </fieldset>
            </div>
        </div>
    </div>
    <script type="text/javascript">
        function dosub(obj) {
            if (obj.title.value == '') {
                layer.msg('标题不能为空！');
                return false;
            }
        }
    </script>
</body>
</html>




